package com.himaci.gtbattle;

import com.badlogic.gdx.Game;
import com.badlogic.gdx.Gdx;
import com.himaci.framework.BaseScreen;
import com.himaci.gtbattle.resource.Assets;
import com.himaci.gtbattle.view.AboutScreen;
import com.himaci.gtbattle.view.GameplayScreen;
import com.himaci.gtbattle.view.LoadingScreen;
import com.himaci.gtbattle.view.MainMenuScreen;

/**
 * Gathe Battle - Arcade Game for Final Assignment
 *
 * @author XNPSDN
 */
public class GTBattle extends Game {

    public static BaseScreen loadingScreen;
    public static BaseScreen aboutScreen;
    public static BaseScreen gameplayScreen;
    public static BaseScreen mainMenuScreen;

    @Override
    public void create() {
	// loading assets
	Assets.getInstance().load();
	loadingScreen = new LoadingScreen(this);	
	aboutScreen = new AboutScreen(this);	
	gameplayScreen = new GameplayScreen(this);	
	mainMenuScreen = new MainMenuScreen(this);

	// set and go
	Gdx.input.setCatchBackKey(true);
	setScreen(loadingScreen);
    }

    @Override
    public void dispose() {
	super.dispose();
	Assets.getInstance().dispose();	
	loadingScreen.dispose();
	aboutScreen.dispose();
	gameplayScreen.dispose();
	mainMenuScreen.dispose();
    }
}
